#include"Timer.h"

Timer::Timer(){
	stopwatch_start = 0;
}

void Timer::reset(){
	stopwatch_start = getTimer();
}

DWORD Timer::getTimer(){
	return (DWORD)timeGetTime();
}

bool Timer::stopwatch(int millisecond){
	if(getTimer() > stopwatch_start + millisecond){
			stopwatch_start = getTimer();
			return true;
	}
	return false;
}